<style scoped></style>

<template>
    <button @click="size++">放大</button>
    <button @click="size--">缩小</button>
    <div class="box" :style="{'font-size':size+'px'}">box</div>
</template>

<script lang="ts" setup>

import { ref } from 'vue';

const size = ref(40);

</script>